﻿@{
    Layout = null;
}
@model List<ElingOA6_DSJCJ.Model.Config> 
@using ElingOA6_DSJCJ.Common;
@{
    string ndate = ViewData["ndate"].ToString();
    }
@helper  GetConfigValue(string keyName, string configClass)
    {
        
        List<ElingOA6_DSJCJ.Model.Config> tmpList = Model.Where(s => s.FKeyName == keyName && s.FConfigClass == configClass).ToList();
        if (tmpList.Count > 0)
        {
            ElingOA6_DSJCJ.Model.Config tmpModel = tmpList[0];
            if (tmpModel.FIsWithDocCls == "Y")
            {
                <a href="/Index/DocumentIndex?keyName=@keyName&keyClass=@configClass">@tmpModel.FShowText</a>
            }
            else
            {
                <a href="@tmpModel.FKeyValue">@tmpModel.FShowText</a>
            }
        }
    }
@helper  GetConfigShowText(string keyName, string configClass, List<ElingOA6_DSJCJ.Model.Config> configList)
    {
        List<ElingOA6_DSJCJ.Model.Config> tmpList = configList.Where(s => s.FKeyName == keyName && s.FConfigClass == configClass).ToList();
        if (tmpList.Count > 0)
        {
    @:@tmpList[0].FShowText
        }

}
@helper  GetConfigValue(string keyName, string configClass, List<ElingOA6_DSJCJ.Model.Config> configList)
    {
        List<ElingOA6_DSJCJ.Model.Config> tmpList = configList.Where(s => s.FKeyName == keyName && s.FConfigClass == configClass).ToList();
        if (tmpList.Count > 0)
        {
    @:@tmpList[0].FKeyValue
        }

    }
    <script type="text/javascript">
        function query() {
            //        var keyName = $("#selChooseDocCls").val();
            var keyName = "-1";
            var keyText = $.trim($('#head_searchText_id').val());
            keyText = escape(keyText);
            if (keyText == "") {
                alert("请输入关键字");
            }
            else {
                window.open("/Index/DocQueryList?keyName=" + keyName + "&keyText=" + keyText, "");
            }
        }
     </script>
    <div class="header">

    </div>

<div class="nav">
    <div class="topNav">
        <a href="@Url.Action("Index","Index")">首页</a>
        @GetConfigValue("nav_link1", "01")
        @GetConfigValue("nav_link2", "01")
        @GetConfigValue("nav_link3", "01")
        @GetConfigValue("nav_link4", "01")
        @GetConfigValue("nav_link5", "01")
        @GetConfigValue("nav_link6", "01")
        @GetConfigValue("nav_link7", "01")
    </div>
    <div class="topHeadeRight">
        <span class="topSearch">
            <input class="topSearchBtn" type="submit" value="">
            <input id="head_searchText_id" name="world" type="text" class="topSearchTxt">
        </span><span class="topSearch" style="border: 0;">
            <input name="" type="image" src="@Url.Content("~/content/images/nav-search.jpg")" onclick="query()"></span>
    </div>
</div>

